﻿#include "FITKAbaAbstractPredefinedField.h"
#include "FITK_Interface/FITKInterfacePhysics/FITKAbstractFields.h"
#include "FITK_Kernel/FITKCore/FITKDataRepo.h"

namespace Interface
{

bool FITKAbaAbstractPredefinedField::hasGetStepManager()
{
    if (m_stepManager != nullptr)
        return true;
    m_stepManager = this->getStepManager(this);
    if (m_stepManager == nullptr)
        return false;
    return true;
}

bool FITKAbaAbstractPredefinedField::getActiveState() const
{
    return m_activeState;
}

void FITKAbaAbstractPredefinedField::setActiveState(bool stat)
{
    m_activeState = stat;
}


void FITKAbaAbstractPredefinedField::setFieldID(const int id)
{
    _fieldID = id;
}

Interface::FITKAbstractFiled* FITKAbaAbstractPredefinedField::getField()
{
    return FITKDATAREPO->getTDataByID<FITKAbstractFiled>(_fieldID);
}

}
